#!/usr/bin/env python
# _*_coding:utf-8_*_

"""
@Time :    2019/10/26 15:56
@Author:  ThinHeader
@File: urls.py
@Software: PyCharm
"""
from django.conf.urls import url

from groupshopping.views import GroupShoppingListView, GroupShoppingAddView, GroupShoppingEditView, \
    GroupShoppingShelveView, GroupShoppingDeleteView, GroupShoppingJoinView, GroupShoppingMobileListView, \
    GroupShoppingGroupView, GroupShoppingPayingNumberView

urlpatterns = [
    # 活动列表
    url(r'^list/(?P<shop_id>[0-9]+)$', GroupShoppingListView.as_view(), name='list'),
    # 活动添加
    url(r'^add/(?P<shop_id>[0-9]+)$', GroupShoppingAddView.as_view(), name='add'),
    url(r'^edit/(?P<shop_id>[0-9]+)$', GroupShoppingEditView.as_view(), name='edit'),
    # 活动上下架
    url(r'^shelve/(?P<shop_id>[0-9]+)$', GroupShoppingShelveView.as_view(), name='shelve'),
    # 活动删除
    url(r'^delete/(?P<shop_id>[0-9]+)$', GroupShoppingDeleteView.as_view(), name='delete'),

    # mobile端路由         带支付业务，不能再加/了，否则商户平台配置无效，支付提示URL未注册
    # 参团页面
    url(r'^join_(?P<product_id>\d+)$', GroupShoppingJoinView.as_view(), name='join'),
    url(r'^group_(?P<group_id>\d+)$', GroupShoppingGroupView.as_view(), name='shopping_group'),
    # 移动端活动列表
    url(r'^mobile_list$', GroupShoppingMobileListView.as_view(), name='mobile_list'),
    url(r'^decrease_group_paying_number$', GroupShoppingPayingNumberView.as_view(), name='decrease_group_paying_number'),
    # 订单路由

]
